import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
import VueMarkdownEditor from '@kangc/v-md-editor';
import '@kangc/v-md-editor/lib/style/base-editor.css';
import vuepressTheme from '@kangc/v-md-editor/lib/theme/vuepress.js';
import '@kangc/v-md-editor/lib/theme/style/vuepress.css';
import Prism from 'prismjs';
import {baseURL} from './utils/config.js';

VueMarkdownEditor.use(vuepressTheme, {
    Prism,
});

// 注册全局变量
Vue.prototype.$baseUpload = baseURL + "/files/upload";
Vue.prototype.$userURL = baseURL.replace('9090', '80') + "/#/user/home";
Vue.prototype.$knife4j = baseURL + "/doc.html#/home";
Vue.prototype.$swagger = baseURL + "/swagger-ui/index.html#/";
Vue.config.productionTip = false;
Vue.use(ElementUI);
Vue.use(VueMarkdownEditor);

new Vue({
    router,
    store,
    render: h => h(App)
}).$mount('#app')
